package com.weipeep.common.domain;

import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.weipeep.common.utils.Util;

import java.util.List;

@JsonIgnoreProperties(ignoreUnknown = true)
@JsonInclude(JsonInclude.Include.NON_NULL)
public class Banji{

    private List<Lesson> lessons;
    public List<Lesson> getLessons() {
        return lessons;
    }

    public void setLessons(List<Lesson> lessons) {
        this.lessons = lessons;
    }
    @JsonIgnoreProperties(ignoreUnknown = true)
    @JsonInclude(JsonInclude.Include.NON_NULL)
    public static class Lesson{
        private Long bsId;
        private int lessonNo;

        public Long getBsId() {
            return bsId;
        }

        public void setBsId(Long bsId) {
            this.bsId = bsId;
        }

        public int getLessonNo() {
            return lessonNo;
        }

        public void setLessonNo(int lessonNo) {
            this.lessonNo = lessonNo;
        }
    }

    public static void main(String[] args) {
        Banji banji = Util.fromJson("{\"schoolId\":1,\"code\":\"GMCP200138Q2B\",\"lessons\":[{\"bsId\":113674678,\"lessonNo\":25,\"isUploadVideo\":1}]}",Banji.class);
        System.out.println(1);
    }
}
